package cn.myzqu.sign.user.server.config;



import cn.myzqu.sign.common.message.wechat.WeChatMessageTemplate;
import cn.myzqu.sign.common.miniprogram.WeChatApp;
import lombok.extern.slf4j.Slf4j;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * 配置微信小程序开发相关信息
 * @Author: 的川
 * @Date: 2018/12/24.
 */
@Configuration
@Slf4j
public class WeChatConfig {

    /**
     * 配置微信小程序
     * @return
     */
    @Bean("WeChatApp")
    public WeChatApp weChatApp(){
        WeChatApp app = new WeChatApp();
        app.setAPPID("wx3fdec941d9e3372d");
        app.setSECRET("4dda86f5fe3128ff8827bc8cd3a91e03");
        log.info("加载微信小程序配置...");
        return app;
    }

    /**
     * 配置微信小程序消息
     * @return
     */
    @Bean
    public WeChatMessageTemplate weChatTemplateMessage(){

        WeChatMessageTemplate templateMessage = new WeChatMessageTemplate();
        log.info("加载微信小程序模板消息配置...");
        return templateMessage;
    }

//    @Bean
//    public QRCode qrCode(){
//        QRCode qrCode = new QRCode();
//        log.info("加载微信小程序二维码配置...");
//        return qrCode;
//    }


}
